<?php


require_once('classes/certificate.class.php');

//echo "<pre>".Certificate::createX509("username","vcsteven@gmail.com","hope is not a strategy")."</pre>";
$array = array();
$array = openssl_x509_parse("-----BEGIN CERTIFICATE-----
MIIDlTCCAv6gAwIBAgIBADANBgkqhkiG9w0BAQUFADCBlDELMAkGA1UEBhMCQkUx
FjAUBgNVBAgTDVdlc3QtRmxhbmRlcnMxDzANBgNVBAcTBkJydWdlczEOMAwGA1UE
ChMFZUNhc2gxGTAXBgNVBAsTEGRldmVsb3BtZW50IHRlYW0xDjAMBgNVBAMTBWVD
YXNoMSEwHwYJKoZIhvcNAQkBFhJ2Y3N0ZXZlbkBnbWFpbC5jb20wHhcNMTAwNTAx
MTg1ODM2WhcNMTEwNTAxMTg1ODM2WjCBlDELMAkGA1UEBhMCQkUxFjAUBgNVBAgT
DVdlc3QtRmxhbmRlcnMxDzANBgNVBAcTBkJydWdlczEOMAwGA1UEChMFZUNhc2gx
GTAXBgNVBAsTEGRldmVsb3BtZW50IHRlYW0xDjAMBgNVBAMTBWVDYXNoMSEwHwYJ
KoZIhvcNAQkBFhJ2Y3N0ZXZlbkBnbWFpbC5jb20wgZ8wDQYJKoZIhvcNAQEBBQAD
gY0AMIGJAoGBAN3QU9Ly9o0+X5vRlHS5B8NdNbtxJ4bzzMEENDW3M6+YsHZ1gy6S
5PtpnCTzOaNmqdaSLX0wUyu/i7mwrWMxk85GHkPQ4luplD9lkSFFIbg56zWS1ypx
KEbmJN6xsgVGWkHVlOZhZ5CpA36hjAYkTLe1hjXCt0X9w3grpj8sVi6HAgMBAAGj
gfQwgfEwHQYDVR0OBBYEFA7DFDDJShkCTGwEu15hkjrJ4so9MIHBBgNVHSMEgbkw
gbaAFA7DFDDJShkCTGwEu15hkjrJ4so9oYGapIGXMIGUMQswCQYDVQQGEwJCRTEW
MBQGA1UECBMNV2VzdC1GbGFuZGVyczEPMA0GA1UEBxMGQnJ1Z2VzMQ4wDAYDVQQK
EwVlQ2FzaDEZMBcGA1UECxMQZG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